
package com.jiuqi.ccp.generator.form;

import java.text.ParseException;
import java.text.SimpleDateFormat;

import javax.servlet.http.HttpServletRequest;

import org.apache.struts.action.ActionError;
import org.apache.struts.action.ActionErrors;
import org.apache.struts.action.ActionForm;
import org.apache.struts.action.ActionMapping;

/**
 * Form for ccpEqTmplt.
 *
 * @author <a href="http://boss.bekk.no/boss/middlegen/"/>Middlegen</a>
 *
 * @struts.form name="ccpEqTmpltForm"
 */
public class CcpEqTmpltForm extends ActionForm {

   private final static SimpleDateFormat FORMAT = new SimpleDateFormat("dd.MM.yyyy hh:mm:ss");

   private java.lang.String _eqtGuid = null;
   private java.lang.String _eqtCode = null;
   private java.lang.String _eqtName = null;
   private java.lang.String _frameCode = null;
   private java.math.BigDecimal _colNum = null;
   private java.lang.String _colWidth = null;
   private java.lang.String _align = null;
   private java.lang.String _conHeight = null;
   private java.lang.String _resultHeight = null;
   private java.lang.String _conWidth = null;
   private java.lang.String _resultWidth = null;
   private java.math.BigDecimal _tagNum = null;
   private java.lang.String _isDefault = null;
   private java.lang.String _reserved1 = null;
   private java.lang.String _reserved2 = null;
   private java.lang.String _reserved3 = null;

   /**
    * Standard constructor.
    */
   public CcpEqTmpltForm() {
   }

   /**
    * Returns the eqtGuid
    *
    * @return the eqtGuid
    */
   public java.lang.String getEqtGuid() {
      return _eqtGuid;
   }

   /**
    * Sets the eqtGuid
    *
    * @param eqtGuid the new eqtGuid value
    */
   public void setEqtGuid(java.lang.String eqtGuid) {
      _eqtGuid = eqtGuid;
   }
   /**
    * Returns the eqtCode
    *
    * @return the eqtCode
    */
   public java.lang.String getEqtCode() {
      return _eqtCode;
   }

   /**
    * Sets the eqtCode
    *
    * @param eqtCode the new eqtCode value
    */
   public void setEqtCode(java.lang.String eqtCode) {
      _eqtCode = eqtCode;
   }
   /**
    * Returns the eqtName
    *
    * @return the eqtName
    */
   public java.lang.String getEqtName() {
      return _eqtName;
   }

   /**
    * Sets the eqtName
    *
    * @param eqtName the new eqtName value
    */
   public void setEqtName(java.lang.String eqtName) {
      _eqtName = eqtName;
   }
   /**
    * Returns the frameCode
    *
    * @return the frameCode
    */
   public java.lang.String getFrameCode() {
      return _frameCode;
   }

   /**
    * Sets the frameCode
    *
    * @param frameCode the new frameCode value
    */
   public void setFrameCode(java.lang.String frameCode) {
      _frameCode = frameCode;
   }
   /**
    * Returns the colNum
    *
    * @return the colNum
    */
   public java.math.BigDecimal getColNum() {
      return _colNum;
   }

   /**
    * Sets the colNum
    *
    * @param colNum the new colNum value
    */
   public void setColNum(java.math.BigDecimal colNum) {
      _colNum = colNum;
   }
   /**
    * Returns the colWidth
    *
    * @return the colWidth
    */
   public java.lang.String getColWidth() {
      return _colWidth;
   }

   /**
    * Sets the colWidth
    *
    * @param colWidth the new colWidth value
    */
   public void setColWidth(java.lang.String colWidth) {
      _colWidth = colWidth;
   }
   /**
    * Returns the align
    *
    * @return the align
    */
   public java.lang.String getAlign() {
      return _align;
   }

   /**
    * Sets the align
    *
    * @param align the new align value
    */
   public void setAlign(java.lang.String align) {
      _align = align;
   }
   /**
    * Returns the conHeight
    *
    * @return the conHeight
    */
   public java.lang.String getConHeight() {
      return _conHeight;
   }

   /**
    * Sets the conHeight
    *
    * @param conHeight the new conHeight value
    */
   public void setConHeight(java.lang.String conHeight) {
      _conHeight = conHeight;
   }
   /**
    * Returns the resultHeight
    *
    * @return the resultHeight
    */
   public java.lang.String getResultHeight() {
      return _resultHeight;
   }

   /**
    * Sets the resultHeight
    *
    * @param resultHeight the new resultHeight value
    */
   public void setResultHeight(java.lang.String resultHeight) {
      _resultHeight = resultHeight;
   }
   /**
    * Returns the conWidth
    *
    * @return the conWidth
    */
   public java.lang.String getConWidth() {
      return _conWidth;
   }

   /**
    * Sets the conWidth
    *
    * @param conWidth the new conWidth value
    */
   public void setConWidth(java.lang.String conWidth) {
      _conWidth = conWidth;
   }
   /**
    * Returns the resultWidth
    *
    * @return the resultWidth
    */
   public java.lang.String getResultWidth() {
      return _resultWidth;
   }

   /**
    * Sets the resultWidth
    *
    * @param resultWidth the new resultWidth value
    */
   public void setResultWidth(java.lang.String resultWidth) {
      _resultWidth = resultWidth;
   }
   /**
    * Returns the tagNum
    *
    * @return the tagNum
    */
   public java.math.BigDecimal getTagNum() {
      return _tagNum;
   }

   /**
    * Sets the tagNum
    *
    * @param tagNum the new tagNum value
    */
   public void setTagNum(java.math.BigDecimal tagNum) {
      _tagNum = tagNum;
   }
   /**
    * Returns the isDefault
    *
    * @return the isDefault
    */
   public java.lang.String getIsDefault() {
      return _isDefault;
   }

   /**
    * Sets the isDefault
    *
    * @param isDefault the new isDefault value
    */
   public void setIsDefault(java.lang.String isDefault) {
      _isDefault = isDefault;
   }
   /**
    * Returns the reserved1
    *
    * @return the reserved1
    */
   public java.lang.String getReserved1() {
      return _reserved1;
   }

   /**
    * Sets the reserved1
    *
    * @param reserved1 the new reserved1 value
    */
   public void setReserved1(java.lang.String reserved1) {
      _reserved1 = reserved1;
   }
   /**
    * Returns the reserved2
    *
    * @return the reserved2
    */
   public java.lang.String getReserved2() {
      return _reserved2;
   }

   /**
    * Sets the reserved2
    *
    * @param reserved2 the new reserved2 value
    */
   public void setReserved2(java.lang.String reserved2) {
      _reserved2 = reserved2;
   }
   /**
    * Returns the reserved3
    *
    * @return the reserved3
    */
   public java.lang.String getReserved3() {
      return _reserved3;
   }

   /**
    * Sets the reserved3
    *
    * @param reserved3 the new reserved3 value
    */
   public void setReserved3(java.lang.String reserved3) {
      _reserved3 = reserved3;
   }


   /**
    * Validate the properties that have been set from this HTTP request,
    * and return an <code>ActionErrors</code> object that encapsulates any
    * validation errors that have been found.  If no errors are found, return
    * <code>null</code> or an <code>ActionErrors</code> object with no
    * recorded error messages.
    *
    * @param mapping The mapping used to select this instance
    * @param request The servlet request we are processing
    */
   public ActionErrors validate(ActionMapping mapping, HttpServletRequest request) {
      ActionErrors errors = new ActionErrors();
      // test for nullity
      if(getEqtGuid() == null) {
         errors.add("eqtGuid", new ActionError("error.eqtGuid.required"));
      }
      // TODO test format/data
      return errors;
   }
}
